
function Save_Excel() {//导出Excel文件
    //getExcelXML有一个JSON对象的配置，配置项看了下只有title配置，为excel文档的标题
//    var data = $('#tt').datagrid('getExcelXml', { title: 'datagrid import to excel' }); //获取datagrid数据对应的excel需要的xml格式的内容
    //用ajax发动到动态页动态写入xls文件中
    var url = '/import/sync/excel.do'; //如果为asp注意修改后缀
    var year =  $("#yearSelect").combobox("getValue");
    var formsid=1;
    $.ajax({ url: url, data: { formsid: formsid }, type: 'POST', dataType: 'text',
        success: function (fn) {
            window.location = fn; //执行下载操作
        },
        error: function (xhr) {
            alert('动态页有问题\nstatus：' + xhr.status + '\nresponseText：' + xhr.responseText)
        }
    });
    return false;
}


function expSave(){
    //if($("#groupId").val() == ''){
    //    alert("请选择会员组");
    //    return false;
    //}
    var top, left, _h,_w, _sh;
    var body = document.documentElement || document.body;
    if(isGecko) body = document.body;
    top = body.scrollTop;
    left = body.scrollLeft;
    _h = body.clientHeight;
    _w = body.scrollWidth;
    _sh = body.scrollHeight;
    top = _h/2 - 150 + top;
    left = (_w - left)/2 - 300;
    _sh = (_sh < _h)?_h:_sh;
    $("#mmms").css("background-color", "#FFFFFF")
        .css("position",'absolute').css("top", top + "px").css("display",'')
        .css("left", left + "px").css('z-index','1000');
    //遮罩层，
    var Dmid = document.createElement("div");
    with(Dmid.style){zIndex = 998;
        position = 'absolute'; width = '100%';
        height = _sh+'px'; overflow = 'hidden'; top = 0; left = 0; border = "0px";
        backgroundColor = '#EEEEEE';if(isIE){filter = " Alpha(Opacity=50)";}else{opacity = 50/100;}}
    Dmid.id = "Dmid";
    document.body.appendChild(Dmid);
    return true;
}
